A circuit unit having a operational amplifier and the like requires that, when an input signal is the similar to a reference value, an output signal should also be zero. That is, the voltage difference of the DC-output signal is required to match that of the DC-input signal. However, the circuit unit has a DC offset caused by variation in a manufacturing process, as the pair of transistors that should be equally manufactured become disproportionate.
If the circuit unit inputs and outputs a differential signal, this DC offset is a difference of the differential output signals when the difference of the differential input signals is zero, and if the difference of the differential output signals becomes zero, the DC offset also becomes zero, which is an ideal state.
Such DC offset is generated by a differential amplifier in the circuit unit, for example. The differential amplifier has a pair of input transistors that is driven according to the difference between the input signal and the reference value or the difference of the differential input signals. The pair of input transistors is usually designed with the same size and the layout is arranged symmetrically, but its threshold voltage or transistor size (gate length and gate width) is varied due to the variation in the manufacturing process and the DC offset occurs. If the above-mentioned DC offset occurs in an analog base band circuit in a communication system, carrier leakage is increased, which is not preferable.
Since occurrence of such the DC offset is unavoidable, a correction unit is provided in order to suppress the DC offset as much as possible. In general, the correction unit monitors an output signal of the circuit unit that should be corrected, searches a correction value so that the output signal matches the reference value, and feeds back the correction value to an input terminal or an internal terminal of the circuit unit.
Such suppression of the DC offset as above is described in the following Patent Documents 1, 2, 3 and the like.    Patent Document 1: Japanese Laid-Open No. 2000-31824    Patent Document 2: Japanese Laid-Open No. 2005-109939    Patent Document 3: Japanese Laid-Open No. 2004-222227
A value of the DC offset is different depending on an integrated circuit device having the circuit unit, and a variation range is not known, either. Thus, it is requested that a correction value with which an output matches the reference value as much as possible is searched automatically in a short time while the output of the circuit unit is monitored, and the circuit unit is corrected by the searched correction value.
One of the searching methods of the correction value is a binary search. In the binary search, while the output corresponding to the correction value is compared with the reference value, the correction value is searched by changing the bit from the most significant bit (MSB) to the least significant bit (LSB) of itself. However, a searched result by the binary search is not necessarily the appropriate value, and a correction value that may not be the best might be found in some cases.